function s = slsizestr(siz)
%SLSIZESTR Makes the formatted size string 
%
% [ Syntax ]
%   - s = slsizestr(siz)
%
% [ Description ]
%   - s = slsizestr(siz) makes a formatted size string giving the row
%     vector of sizes. Suppose siz is [3 4 5], then it returns '3x4x5'.
%
% [ History ]
%   - Created by Dahua Lin, on Dec 21, 2007
%

assert(isnumeric(siz) && ndims(siz) == 2 && size(siz, 1) == 1, ...
    'sltoolbox:slsizestr:invalidarg', ...
    'siz should be a numeric row vector.');

if isscalar(siz)
    s = int2str(siz);
else
    s = [num2str(siz(1:end-1), '%dx'), int2str(siz(end))];
end
